﻿using System;
using System.Collections.Generic;
using System.Web;

using mvcForum.Core.Interfaces;
using mvcForum.Web.Services;
using mvcForum.Core.Interfaces.DependencyManagement;

namespace mvcForum.Web.DependencyBuilders {

	public class StorageBuilder : IDependencyBuilder {

		public void Configure(IDependencyContainer container) {
			IAttachmentStorage storage = new NTFSAttachmentStorage(HttpContext.Current.Server.MapPath("~"), "/attachments");
			container.RegisterSingleton<IAttachmentStorage>(storage);
		}

		public void ValidateRequirements(IList<ApplicationRequirement> feedback) { }
	}
}